Changes between Initial Version and Version 1 of XmlRpcCheckMovieHash


Ignore:
Timestamp:
Sep 28, 2008, 1:24:34 PM (16 years ago)
Author:
guest
Comment:

Created this page [Majky]

Legend:

Unmodified
Added
Removed
Modified
  • XmlRpcCheckMovieHash

    v1 v1  
     1
     2[[PageOutline(3-4, Sections)]]
     3
     4== !CheckMovieHash ==
     5
     6
     7=== Intro ===
     8
     9  check if video file hashes are already stored in the database
     10
     11
     12----
     13=== Description ===
     14
     15  '''struct !CheckMovieHash(string $token, array($moviehash, $moviehash, ...) $hashes)'''
     16 
     17  Checks if given video file hashes ''hashes'' are already stored in the database.
     18 
     19  If found, the server will return basic movie information, including IMDb ID, movie title, release year.
     20 
     21  This information can be then used in client application to automatically fill (or verify) movie info.
     22
     23
     24----
     25=== Parameters ===
     26
     27  ''token (required)''::
     28    token string identifying user's session, taken from [wiki:XmlRpcLogIn LogIn] output structure.
     29  ''hashes (required)''::
     30    array/list of [wiki:HashSourceCodes video file hashes]
     31
     32
     33----
     34=== Return Values ===
     35
     36  Output is returned in this structure:
     37{{{
     38  struct(
     39    struct( <-- list of movie info structures
     40      struct( <-- movie information structure (movieinfo)
     41        (string) [MovieHash],
     42        (string) [MovieImdbID],
     43        (string) [MovieName],
     44        (string) [MovieYear]
     45      ) [<video file hash>],
     46      struct( movieinfo ) [<video file hash>],
     47     
     48      ... more movie information structures go here (if any) ...
     49     
     50    ) [data],
     51    (double) [seconds]
     52  )
     53}}}
     54
     55  and contains these elements:
     56
     57  The returned structure contains these elements:
     58    ''status''::
     59      function result code, see [wiki:XmlRpcStatusCode list of status codes]
     60    ''data''::
     61      list of movie info structures ''movieinfo''
     62    ''movieinfo''::
     63      information about a movie containing:
     64        * ''!MovieHash'': video file hash, you can use this value to match the movie info to your input parameters
     65        * ''MovieImdbID'': movie IMDb ID
     66        * ''!MovieName'': movie title
     67        * ''!MovieYear'': movie release year
     68    ''seconds''::
     69      time taken to execute this command on server
     70
     71
     72----
     73=== Implementations ===
     74
     75  There are currently no available sample implementations.
     76
     77
     78----
     79=== Changelog ===
     80
     81  Version 1: created this function
     82
     83
     84----
     85=== Examples ===
     86
     87
     88==== Input ====
     89 
     90{{{
     91#!xml
     92<methodCall>
     93 <methodName>CheckMovieHash</methodName>
     94 <params>
     95  <param>
     96   <value><string>gqb4qjfkc66vb0sarm8j60o3t7</string></value>
     97  </param>
     98  <param>
     99   <value>
     100    <array>
     101     <data>
     102      <value><string>d7aa0275cace4410</string></value>
     103      <value><string>ca8f3c95403dd70f</string></value>
     104     
     105      ... more video file hashes go here (if any) ...
     106     
     107     </data>
     108    </array>
     109   </value>
     110  </param>
     111 </params>
     112</methodCall>
     113}}}
     114
     115 
     116==== Output ====
     117
     118{{{
     119#!xml
     120<methodResponse>
     121 <params>
     122  <param>
     123   <value>
     124    <struct>
     125     <member>
     126      <name>status</name>
     127      <value><string>200 OK</string></value>
     128     </member>
     129     <member>
     130      <name>data</name>
     131      <value>
     132       <struct>
     133        <member>
     134         <name>d7aa0275cace4410</name>
     135         <value>
     136          <struct>
     137           <member>
     138            <name>MovieHash</name>
     139            <value><string>d7aa0275cace4410</string></value>
     140           </member>
     141           <member>
     142            <name>MovieImdbID</name>
     143            <value><string>371746</string></value>
     144           </member>
     145           <member>
     146            <name>MovieName</name>
     147            <value><string>Iron Man</string></value>
     148           </member>
     149           <member>
     150            <name>MovieYear</name>
     151            <value><string>2008</string></value>
     152           </member>
     153          </struct>
     154         
     155          ... more movie information structures go here (if any) ...
     156         
     157         </value>
     158        </member>
     159       </struct>
     160      </value>
     161     </member>
     162     <member>
     163      <name>seconds</name>
     164      <value><double>3.525</double></value>
     165     </member>
     166    </struct>
     167   </value>
     168  </param>
     169 </params>
     170</methodResponse>
     171}}}
     172
     173
     174----
     175=== Notes ===
     176
     177  none yet
     178
     179
     180----
     181=== See also ===
     182
     183
     184----
     185=== Comments ===
     186
     187        add your comments, hints and suggestions here if you like ...
     188
     189
     190--------
     191[Prev] [wiki:XmlRpcIntro Home] [Next]